# Contributor: Bart Ribbers <bribbers@disroot.org>

# The group tag is just to easily find this APKBUILD by some scripts for automation
# group=kde-applications
maintainer="team/kde <bribbers@disroot.org>"
pkgname=kdegraphics-mobipocket
pkgver=24.08.2
pkgrel=0
pkgdesc="A collection of plugins to handle mobipocket files"
# armhf blocked by extra-cmake-modules
arch="all !armhf"
url="https://www.kde.org/applications/graphics/"
license="GPL-2.0-or-later"
depends_dev="
	qt6-qtbase-dev
	kio-dev
	"
makedepends="$depends_dev
	extra-cmake-modules
	samurai
	"
subpackages="$pkgname-dev"
_repo_url="https://invent.kde.org/graphics/kdegraphics-mobipocket.git"
source="https://download.kde.org/stable/release-service/$pkgver/src/kdegraphics-mobipocket-$pkgver.tar.xz"
options="!check" # No tests

build() {
	cmake -B build -G Ninja \
		-DBUILD_WITH_QT6=ON \
		-DCMAKE_BUILD_TYPE=RelWithDebInfo \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib
	cmake --build build
}

package() {
	DESTDIR="$pkgdir" cmake --install build
}

sha512sums="
bb302873e040e6dc0bb72626b6fb3f3cb05040c0cdabbefae23f3031b133078666f9118711ec7d31bddbdacecef5a9753729719157a6d35b676191e188b730bf  kdegraphics-mobipocket-24.08.2.tar.xz
"
